const { defineConfig } = require("@vue/cli-service");
module.exports = defineConfig({
  publicPath: "./",
  outputDir: "dist",
  assetsDir: "static",
  lintOnSave: false,
  productionSourceMap: false,
  transpileDependencies: true,
  devServer: {
    //记住，别写错了devServer//设置本地默认端口  选填
    historyApiFallback: true,
    port: 82,
    proxy: {
      //设置代理，必须填
      "/api": {
        // 目标代理服务器地址：部署时将localhost改成自己服务器的地址即可
        target: "http://localhost:9800",
        changeOrigin: true, //是否设置同源，输入是的
        pathRewrite: {
          "^/api": "", //选择忽略拦截器里面的内容
        },
      },
    },
  },
});
